@extends('layouts.app')

@section('content')
<div class="login-wrapper">
    <div class="login">
        <div class="slogan"></div>
        <div class="form">
            <div class="form-inner">
                <form class="form-horizontal" role="form" method="POST" action="{{ url('/login') }}">
                    {{ csrf_field() }}
                    <div class="logo"></div>
                    <div class="form-item">
                        <h4 class="title">用户登录</h4>
                    </div>
                    <div class="form-item">
                        <i class="login-icon icon-username"></i>
                        <input
                            required
                            autofocus
                            type="text"
                            id="login"
                            name="login"
                            class="form-input"
                            value="{{ old('login') }}"
                            placeholder="请输入邮箱、手机"
                        />
                    </div>
                    <div class="form-item">
                        <i class="login-icon icon-password"></i>
                        <input
                            required
                            type="password"
                            id="password"
                            name="password"
                            class="form-input"
                            placeholder="请输入密码"
                        />
                    </div>
                    <div class="form-item">
                        <button type="submit" class="form-button">登录</button>
                        <div class="forget">
                            <a href="/forget/password" class="fr">忘记密码？</a>
                            @if ($errors->has('login') or $errors->has('password'))
                                <span class="form-error">账号或密码错误</span>
                            @endif
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
@endsection
